3.98 \(\int \cos ^3(a+b \log (c x^n)) \, dx\)

Optimal. Leaf size=149 \[ \frac{6 b^3 n^3 x \sin \left (a+b \log \left (c x^n\right )\right )}{9 b^4 n^4+10 b^2 n^2+1}+\frac{x \cos ^3\left (a+b \log \left (c x^n\right )\right )}{9 b^2 n^2+1}+\frac{6 b^2 n^2 x \cos \left (a+b \log \left (c x^n\right )\right )}{9 b^4 n^4+10 b^2 n^2+1}+\frac{3 b n x \sin \left (a+b \log \left (c x^n\right )\right ) \cos ^2\left (a+b \log \left (c x^n\right )\right )}{9 b^2 n^2+1} \]

[Out]

(6*b^2*n^2*x*Cos[a + b*Log[c*x^n]])/(1 + 10*b^2*n^2 + 9*b^4*n^4) + (x*Cos[a + b*Log[c*x^n]]^3)/(1 + 9*b^2*n^2)
 + (6*b^3*n^3*x*Sin[a + b*Log[c*x^n]])/(1 + 10*b^2*n^2 + 9*b^4*n^4) + (3*b*n*x*Cos[a + b*Log[c*x^n]]^2*Sin[a +
 b*Log[c*x^n]])/(1 + 9*b^2*n^2)

________________________________________________________________________________________

Rubi [A]  time = 0.036033, antiderivative size = 149, normalized size of antiderivative = 1., number of steps used = 2, number of rules used = 2, integrand size = 13, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.154, Rules used = {4478, 4476} \[ \frac{6 b^3 n^3 x \sin \left (a+b \log \left (c x^n\right )\right )}{9 b^4 n^4+10 b^2 n^2+1}+\frac{x \cos ^3\left (a+b \log \left (c x^n\right )\right )}{9 b^2 n^2+1}+\frac{6 b^2 n^2 x \cos \left (a+b \log \left (c x^n\right )\right )}{9 b^4 n^4+10 b^2 n^2+1}+\frac{3 b n x \sin \left (a+b \log \left (c x^n\right )\right ) \cos ^2\left (a+b \log \left (c x^n\right )\right )}{9 b^2 n^2+1} \]

Antiderivative was successfully verified.

[In]

Int[Cos[a + b*Log[c*x^n]]^3,x]

[Out]

(6*b^2*n^2*x*Cos[a + b*Log[c*x^n]])/(1 + 10*b^2*n^2 + 9*b^4*n^4) + (x*Cos[a + b*Log[c*x^n]]^3)/(1 + 9*b^2*n^2)
 + (6*b^3*n^3*x*Sin[a + b*Log[c*x^n]])/(1 + 10*b^2*n^2 + 9*b^4*n^4) + (3*b*n*x*Cos[a + b*Log[c*x^n]]^2*Sin[a +
 b*Log[c*x^n]])/(1 + 9*b^2*n^2)

Rule 4478

Int[Cos[((a_.) + Log[(c_.)*(x_)^(n_.)]*(b_.))*(d_.)]^(p_), x_Symbol] :> Simp[(x*Cos[d*(a + b*Log[c*x^n])]^p)/(
b^2*d^2*n^2*p^2 + 1), x] + (Dist[(b^2*d^2*n^2*p*(p - 1))/(b^2*d^2*n^2*p^2 + 1), Int[Cos[d*(a + b*Log[c*x^n])]^
(p - 2), x], x] + Simp[(b*d*n*p*x*Cos[d*(a + b*Log[c*x^n])]^(p - 1)*Sin[d*(a + b*Log[c*x^n])])/(b^2*d^2*n^2*p^
2 + 1), x]) /; FreeQ[{a, b, c, d, n}, x] && IGtQ[p, 1] && NeQ[b^2*d^2*n^2*p^2 + 1, 0]

Rule 4476

Int[Cos[((a_.) + Log[(c_.)*(x_)^(n_.)]*(b_.))*(d_.)], x_Symbol] :> Simp[(x*Cos[d*(a + b*Log[c*x^n])])/(b^2*d^2
*n^2 + 1), x] + Simp[(b*d*n*x*Sin[d*(a + b*Log[c*x^n])])/(b^2*d^2*n^2 + 1), x] /; FreeQ[{a, b, c, d, n}, x] &&
 NeQ[b^2*d^2*n^2 + 1, 0]

Rubi steps

\begin{align*} \int \cos ^3\left (a+b \log \left (c x^n\right )\right ) \, dx &=\frac{x \cos ^3\left (a+b \log \left (c x^n\right )\right )}{1+9 b^2 n^2}+\frac{3 b n x \cos ^2\left (a+b \log \left (c x^n\right )\right ) \sin \left (a+b \log \left (c x^n\right )\right )}{1+9 b^2 n^2}+\frac{\left (6 b^2 n^2\right ) \int \cos \left (a+b \log \left (c x^n\right )\right ) \, dx}{1+9 b^2 n^2}\\ &=\frac{6 b^2 n^2 x \cos \left (a+b \log \left (c x^n\right )\right )}{1+10 b^2 n^2+9 b^4 n^4}+\frac{x \cos ^3\left (a+b \log \left (c x^n\right )\right )}{1+9 b^2 n^2}+\frac{6 b^3 n^3 x \sin \left (a+b \log \left (c x^n\right )\right )}{1+10 b^2 n^2+9 b^4 n^4}+\frac{3 b n x \cos ^2\left (a+b \log \left (c x^n\right )\right ) \sin \left (a+b \log \left (c x^n\right )\right )}{1+9 b^2 n^2}\\ \end{align*}

Mathematica [A]  time = 0.41392, size = 117, normalized size = 0.79 \[ \frac{x \left (3 \left (9 b^2 n^2+1\right ) \cos \left (a+b \log \left (c x^n\right )\right )+\left (b^2 n^2+1\right ) \cos \left (3 \left (a+b \log \left (c x^n\right )\right )\right )+6 b n \sin \left (a+b \log \left (c x^n\right )\right ) \left (\left (b^2 n^2+1\right ) \cos \left (2 \left (a+b \log \left (c x^n\right )\right )\right )+5 b^2 n^2+1\right )\right )}{36 b^4 n^4+40 b^2 n^2+4} \]

Antiderivative was successfully verified.

[In]

Integrate[Cos[a + b*Log[c*x^n]]^3,x]

[Out]

(x*(3*(1 + 9*b^2*n^2)*Cos[a + b*Log[c*x^n]] + (1 + b^2*n^2)*Cos[3*(a + b*Log[c*x^n])] + 6*b*n*(1 + 5*b^2*n^2 +
 (1 + b^2*n^2)*Cos[2*(a + b*Log[c*x^n])])*Sin[a + b*Log[c*x^n]]))/(4 + 40*b^2*n^2 + 36*b^4*n^4)

________________________________________________________________________________________

Maple [F]  time = 0.095, size = 0, normalized size = 0. \begin{align*} \int \left ( \cos \left ( a+b\ln \left ( c{x}^{n} \right ) \right ) \right ) ^{3}\, dx \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(cos(a+b*ln(c*x^n))^3,x)

[Out]

int(cos(a+b*ln(c*x^n))^3,x)

________________________________________________________________________________________

Maxima [B]  time = 1.22745, size = 1335, normalized size = 8.96 \begin{align*} \text{result too large to display} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(cos(a+b*log(c*x^n))^3,x, algorithm="maxima")

[Out]

1/8*((3*(b^3*cos(3*b*log(c))*sin(6*b*log(c)) - b^3*cos(6*b*log(c))*sin(3*b*log(c)) + b^3*sin(3*b*log(c)))*n^3
+ (b^2*cos(6*b*log(c))*cos(3*b*log(c)) + b^2*sin(6*b*log(c))*sin(3*b*log(c)) + b^2*cos(3*b*log(c)))*n^2 + 3*(b
*cos(3*b*log(c))*sin(6*b*log(c)) - b*cos(6*b*log(c))*sin(3*b*log(c)) + b*sin(3*b*log(c)))*n + cos(6*b*log(c))*
cos(3*b*log(c)) + sin(6*b*log(c))*sin(3*b*log(c)) + cos(3*b*log(c)))*x*cos(3*b*log(x^n) + 3*a) + 3*(9*(b^3*cos
(3*b*log(c))*sin(4*b*log(c)) - b^3*cos(4*b*log(c))*sin(3*b*log(c)) + b^3*cos(2*b*log(c))*sin(3*b*log(c)) - b^3
*cos(3*b*log(c))*sin(2*b*log(c)))*n^3 + 9*(b^2*cos(4*b*log(c))*cos(3*b*log(c)) + b^2*cos(3*b*log(c))*cos(2*b*l
og(c)) + b^2*sin(4*b*log(c))*sin(3*b*log(c)) + b^2*sin(3*b*log(c))*sin(2*b*log(c)))*n^2 + (b*cos(3*b*log(c))*s
in(4*b*log(c)) - b*cos(4*b*log(c))*sin(3*b*log(c)) + b*cos(2*b*log(c))*sin(3*b*log(c)) - b*cos(3*b*log(c))*sin
(2*b*log(c)))*n + cos(4*b*log(c))*cos(3*b*log(c)) + cos(3*b*log(c))*cos(2*b*log(c)) + sin(4*b*log(c))*sin(3*b*
log(c)) + sin(3*b*log(c))*sin(2*b*log(c)))*x*cos(b*log(x^n) + a) + (3*(b^3*cos(6*b*log(c))*cos(3*b*log(c)) + b
^3*sin(6*b*log(c))*sin(3*b*log(c)) + b^3*cos(3*b*log(c)))*n^3 - (b^2*cos(3*b*log(c))*sin(6*b*log(c)) - b^2*cos
(6*b*log(c))*sin(3*b*log(c)) + b^2*sin(3*b*log(c)))*n^2 + 3*(b*cos(6*b*log(c))*cos(3*b*log(c)) + b*sin(6*b*log
(c))*sin(3*b*log(c)) + b*cos(3*b*log(c)))*n - cos(3*b*log(c))*sin(6*b*log(c)) + cos(6*b*log(c))*sin(3*b*log(c)
) - sin(3*b*log(c)))*x*sin(3*b*log(x^n) + 3*a) + 3*(9*(b^3*cos(4*b*log(c))*cos(3*b*log(c)) + b^3*cos(3*b*log(c
))*cos(2*b*log(c)) + b^3*sin(4*b*log(c))*sin(3*b*log(c)) + b^3*sin(3*b*log(c))*sin(2*b*log(c)))*n^3 - 9*(b^2*c
os(3*b*log(c))*sin(4*b*log(c)) - b^2*cos(4*b*log(c))*sin(3*b*log(c)) + b^2*cos(2*b*log(c))*sin(3*b*log(c)) - b
^2*cos(3*b*log(c))*sin(2*b*log(c)))*n^2 + (b*cos(4*b*log(c))*cos(3*b*log(c)) + b*cos(3*b*log(c))*cos(2*b*log(c
)) + b*sin(4*b*log(c))*sin(3*b*log(c)) + b*sin(3*b*log(c))*sin(2*b*log(c)))*n - cos(3*b*log(c))*sin(4*b*log(c)
) + cos(4*b*log(c))*sin(3*b*log(c)) - cos(2*b*log(c))*sin(3*b*log(c)) + cos(3*b*log(c))*sin(2*b*log(c)))*x*sin
(b*log(x^n) + a))/(9*(b^4*cos(3*b*log(c))^2 + b^4*sin(3*b*log(c))^2)*n^4 + 10*(b^2*cos(3*b*log(c))^2 + b^2*sin
(3*b*log(c))^2)*n^2 + cos(3*b*log(c))^2 + sin(3*b*log(c))^2)

________________________________________________________________________________________

Fricas [A]  time = 0.500971, size = 308, normalized size = 2.07 \begin{align*} \frac{6 \, b^{2} n^{2} x \cos \left (b n \log \left (x\right ) + b \log \left (c\right ) + a\right ) +{\left (b^{2} n^{2} + 1\right )} x \cos \left (b n \log \left (x\right ) + b \log \left (c\right ) + a\right )^{3} + 3 \,{\left (2 \, b^{3} n^{3} x +{\left (b^{3} n^{3} + b n\right )} x \cos \left (b n \log \left (x\right ) + b \log \left (c\right ) + a\right )^{2}\right )} \sin \left (b n \log \left (x\right ) + b \log \left (c\right ) + a\right )}{9 \, b^{4} n^{4} + 10 \, b^{2} n^{2} + 1} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(cos(a+b*log(c*x^n))^3,x, algorithm="fricas")

[Out]

(6*b^2*n^2*x*cos(b*n*log(x) + b*log(c) + a) + (b^2*n^2 + 1)*x*cos(b*n*log(x) + b*log(c) + a)^3 + 3*(2*b^3*n^3*
x + (b^3*n^3 + b*n)*x*cos(b*n*log(x) + b*log(c) + a)^2)*sin(b*n*log(x) + b*log(c) + a))/(9*b^4*n^4 + 10*b^2*n^
2 + 1)

________________________________________________________________________________________

Sympy [F(-1)]  time = 0., size = 0, normalized size = 0. \begin{align*} \text{Timed out} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(cos(a+b*ln(c*x**n))**3,x)

[Out]

Timed out

________________________________________________________________________________________

Giac [F(-1)]  time = 0., size = 0, normalized size = 0. \begin{align*} \text{Timed out} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(cos(a+b*log(c*x^n))^3,x, algorithm="giac")

[Out]

Timed out